package com.rongke.service.impl;

import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import com.rongke.mapper.LoanOrderMapper;
import com.rongke.model.LoanOrder;
import com.rongke.service.LoanOrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

/**
 * @version : Ver 1.0
 * @LoanOrderServiceImpl
 * @ServiceImpl
 */
@Service
public class LoanOrderServiceImpl extends ServiceImpl<LoanOrderMapper, LoanOrder> implements LoanOrderService {
    @Autowired
    private LoanOrderMapper loanOrderMapper;
    /**
     * @查询申请贷款列表
     */
    public List<LoanOrder> selectApplyLoanList(Map<String,Object> map){
        return loanOrderMapper.selectApplyLoanList(map);
    }


   /**
     * 查找申请贷款订单数量
     * @param map
     * @return
     */
   public int selectApplyLoanListNum(Map<String, Object> map){
       return  loanOrderMapper.selectApplyLoanListNum(map);
   }

    /**
     * 查找待打款订单数量
     * @param map
     * @return
     */
   public int selectToPassMoneyListNum(Map<String, Object> map){
       return  loanOrderMapper.selectToPassMoneyListNum(map);
   }

    /**
     * 查找所有的待打款订单
     * @param map
     * @return
     */
   public  List<LoanOrder>  selectToPassMoneyList(Map<String, Object> map){
         return loanOrderMapper.selectToPassMoneyList(map);
   }


    /**
     * 查找打款失败订单数量
     * @param map
     * @return
     */
    public int selectFailToPassMoneyListNum(Map<String, Object> map){
        return  loanOrderMapper.selectFailToPassMoneyListNum(map);
    }

    /**
     * 查找所有的打款失败订单
     * @param map
     * @return
     */
    public  List<LoanOrder>  selectFailToPassMoneyList(Map<String, Object> map){
        return loanOrderMapper.selectFailToPassMoneyList(map);
    }

    /**
     * 查询申请失败列表数量
     * @param map
     * @return
     */
   public int selectFailApplyListNum(Map<String, Object> map){
       return loanOrderMapper.selectFailApplyListNum(map);
   }


    /**
     * 查询申请失败列表
     * @param map
     * @return
     */
    public List<LoanOrder> selectFailApplyList(Map<String, Object> map){

        return loanOrderMapper.selectFailApplyList(map);
    }


    /**
     * 查询所有的打款列表
     * @param map
     * @return
     */
    public List<LoanOrder> selectAllPassMoneyList(Map<String, Object> map){
        return  loanOrderMapper.selectAllPassMoneyList(map);
    }

    public int selectAllPassMoneyListNum(Map<String, Object> map){
        return loanOrderMapper.selectAllPassMoneyListNum(map);
    }


    public  List<LoanOrder> selectNormalRepaymentList(Map<String, Object> map){
        return loanOrderMapper.selectNormalRepaymentList(map);
    }
    public int selectNormalRepaymentListNum(Map<String, Object> map){
        return loanOrderMapper.selectNormalRepaymentListNum(map);
    }


    public double selectPeopleSum(Map<String, Object> map){
        return loanOrderMapper.selectPeopleSum(map);
    }

    public double selectMoneySum(Map<String, Object> map){
        return loanOrderMapper.selectMoneySum(map);
    }

    public double selectPeopleSum1(Map<String, Object> map){
        return loanOrderMapper.selectPeopleSum1(map);
    }

    public double selectMoneySum1(Map<String, Object> map){
        return loanOrderMapper.selectMoneySum1(map);
    }

    public double selectPeopleSum2(Map<String, Object> map){  return loanOrderMapper.selectPeopleSum2(map);  }

    public double selectMoneySum2(Map<String, Object> map){
        return loanOrderMapper.selectMoneySum2(map);
    }

    public String selectPeopleSum3(Map<String, Object> map){ return loanOrderMapper.selectPeopleSum3(map); }

    public String selectMoneySum3(Map<String, Object> map){ return loanOrderMapper.selectMoneySum3(map);    }

    public double selectPeopleSum6(Map<String, Object> map){ return loanOrderMapper.selectPeopleSum6(map); }

    public double selectMoneySum6(Map<String, Object> map){ return loanOrderMapper.selectMoneySum6(map); }

    public double selectPeopleSum7(Map<String, Object> map){ return loanOrderMapper.selectPeopleSum7(map); }

    public double selectMoneySum7(Map<String, Object> map){ return loanOrderMapper.selectMoneySum7(map); }

    public double selectPeopleSum8(Map<String, Object> map){ return loanOrderMapper.selectPeopleSum8(map); }

    public double selectMoneySum8(Map<String, Object> map){ return loanOrderMapper.selectMoneySum8(map); }

    public double selectPeopleSum9(Map<String, Object> map){ return loanOrderMapper.selectPeopleSum9(map); }

    public double selectMoneySum9(Map<String, Object> map){ return loanOrderMapper.selectMoneySum9(map); }


    /**
     * 黑名单查询
     * @param map
     * @return
     */

    public List<LoanOrder> selectBlackList(Map<String, Object> map){
        return  loanOrderMapper.selectBlackList(map);
    }

    public int selectBlackListNum(Map<String, Object> map){
        return loanOrderMapper.selectBlackListNum(map);
    }


   public List<LoanOrder> selectOverDueList(Map<String, Object> map){
    return loanOrderMapper.selectOverDueList(map);
   }


  public  int selectOverDueListNum(Map<String, Object> map){
      return loanOrderMapper.selectOverDueListNum(map);
  }

    public List<LoanOrder> overDuePaymentList(Map<String, Object> map){
        return loanOrderMapper.overDuePaymentList(map);
    }


    public  int overDuePaymentListNum(Map<String, Object> map){
        return loanOrderMapper.overDuePaymentListNum(map);
    }

    /**
     * 分页查询坏账列表
     * @param map
     * @return
     */
    public List<LoanOrder> selectBadDebtList(Map<String, Object> map){
        return  loanOrderMapper.selectBadDebtList(map);
    }


    public int selectBadDebtListNum(Map<String, Object> map){
        return loanOrderMapper.selectBadDebtListNum(map);
    }



    public List<LoanOrder> selectNormalToPayList(Map<String, Object> map){
        return  loanOrderMapper.selectNormalToPayList(map);
    }


    public int selectNormalToPayListNum(Map<String, Object> map){
        return loanOrderMapper.selectNormalToPayListNum(map);
    }


    public List<LoanOrder> selectThisOrder(){
        return loanOrderMapper.selectThisOrder();
    };

    public BigDecimal sumAllWateMoney(){
        return loanOrderMapper.sumAllWateMoney();
    }

    @Override
    public List<LoanOrder> selectApplyByTime(String startTime, String endTime) {
        return loanOrderMapper.selectApplyByTime(startTime,endTime);
    }

    @Override
    public List<LoanOrder> selectApplyStatus(Long id) {
        return loanOrderMapper.selectApplyStatus(id);
    }

    @Override
    public List<LoanOrder> selectSB(Map<String, Object> map) {
        return loanOrderMapper.selectSB(map);
    }


}
